#include "bp_utils.h"

void * _BP_API bp_alloc_zero(size_t count, size_t sz)
{
	if (count == 0 || sz == 0) {
		return NULL;
	}

	return calloc(count, sz);
}

void * _BP_API bp_alloc(size_t count, size_t sz)
{
	return malloc(count * sz);
}

void _BP_API bp_free(void *p)
{
	free(p);
}

//uint32_t _BP_API _bp_dword_be2le(uint32_t be)
//{
//	return (uint32_t)_BP_BIG_ENDIAN_DWORD_BYTE0(be)
//		| ((uint32_t)_BP_BIG_ENDIAN_DWORD_BYTE1(be) << 8)
//		| ((uint32_t)_BP_BIG_ENDIAN_DWORD_BYTE2(be) << 16)
//		| ((uint32_t)_BP_BIG_ENDIAN_DWORD_BYTE3(be) << 24);
//}